#include "contactnameitem.h"
#include "ui_contactnameitem.h"

ContactNameItem::ContactNameItem(QWidget *parent) :
    QWidget(parent),
    ui(new Ui::ContactNameItem)
{
    ui->setupUi(this);
}

ContactNameItem::~ContactNameItem()
{
    delete ui;
}

void ContactNameItem::item(Group *data)
{
    if (data == NULL) {
        return;
    }
    this->data = data;
    ui->label->setText(data->groupName());
    if (data->groupName() == "新的朋友") {
        ui->line->setVisible(false);
    }
}
